#extconf.rb
require "mkmf"

if `which make`.strip.empty?
  STDERR.puts "\n\n"
  STDERR.puts "***************************************************************************************"
  STDERR.puts "*************** make required (apt-get install make build-essential) =( ***************"
  STDERR.puts "***************************************************************************************"
  exit(1)
end

$CXXFLAGS ||= ''
$CFLAGS = ["-Wall -Werror=return-type -std=c99",$CFLAGS].join(" ")
$CXXFLAGS = ["-Wall -Werror=return-type -std=c++11",$CXXFLAGS].join(" ")
#$LDFLAGS = ["-static-libstdc++ -static-libgcc",$LDFLAGS].join(" ")

have_header("dirent.h")
create_makefile("enhanceutils")
